这个错误查了好久,最后在medium上找到了答案,遂记于此!
系统: mac os
错误信息:
/launchpad.net/gozk/zookeeper/zk.go:15:10: fatal error: 'zookeeper.h' file not found
solution:
文件$GOPATH/src/launchpad.net/gozk/zookeeper/zk.go
中
...
package zookeeper
/*
#cgo CFLAGS: -I/usr/include/c-client-src -I/usr/include/zookeeper
#cgo LDFLAGS: -lzookeeper_mt
...
修改为
...
package zookeeper
/*
#cgo CFLAGS: -I/usr/include/c-client-src -I/usr/include/zookeeper -I/usr/local/include/zookeeper
#cgo LDFLAGS: /usr/local/lib/libzookeeper_mt.a
...
**粗体** _斜体_ [链接](http://example.com) `代码` - 列表 > 引用
。你还可以使用@
来通知其他用户。